﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Trang_web/Khach_Hang.master" AutoEventWireup="true" CodeFile="Trang_Don_Dat_Hang_Cu.aspx.cs" Inherits="Trang_web_Trang_Don_Dat_Hang_Cu" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolderNoiDung" Runat="Server">
    <asp:GridView ID="GridViewDDH" runat="server" AllowPaging="True" 
        AutoGenerateColumns="False" CellPadding="4" DataKeyNames="Id" 
        ForeColor="#333333" GridLines="None" Visible="False" Width="550px" 
        onselectedindexchanged="GridViewDDH_SelectedIndexChanged">
        <AlternatingRowStyle BackColor="White" />
        <Columns>
            <asp:BoundField DataField="Id" HeaderText="Mã" />
            <asp:BoundField DataField="NgayDat" HeaderText="Ngày đặt" />
            <asp:BoundField DataField="NgayGiao" HeaderText="Ngày giao" />
            <asp:BoundField DataField="TongTien" 
                DataFormatString="{0:#,###}" HeaderText="Tổng tiền" />
            <asp:CommandField ButtonType="Button" SelectText="Chọn" 
                ShowSelectButton="True" />
        </Columns>
        <EditRowStyle BackColor="#7C6F57" />
        <FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
        <HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
        <RowStyle BackColor="#E3EAEB" />
        <SelectedRowStyle BackColor="#FF66CC" Font-Bold="True" ForeColor="#333333" />
        <SortedAscendingCellStyle BackColor="#F8FAFA" />
        <SortedAscendingHeaderStyle BackColor="#246B61" />
        <SortedDescendingCellStyle BackColor="#D4DFE1" />
        <SortedDescendingHeaderStyle BackColor="#15524A" />
    </asp:GridView>
    <br />
    <div align="center">
    Thông tin đơn đặt hàng
    <asp:GridView ID="GridViewCTDDH" runat="server" AllowPaging="True" 
            AutoGenerateColumns="False" BackColor="White" BorderColor="#E7E7FF" 
            BorderStyle="None" BorderWidth="1px" CellPadding="3" GridLines="Horizontal">
        <AlternatingRowStyle BackColor="#F7F7F7" />
        <Columns>
            <asp:TemplateField HeaderText="Sách">
                <ItemTemplate>
                    <table cellpadding="0" cellspacing="0">
                        <tr>
                            <td valign="top" width="80px">
                                &nbsp;&nbsp;<asp:Image ID="Image_sach" runat="server" Height="100px" 
                                    ImageUrl='<%# "~/MyPhoto.ashx?ID=" + Eval("IdSach") %>' Width="80px" />
                            </td>
                        </tr>
                        <tr>
                            <td valign="top" width="80px">
                                <br />
                                <asp:HyperLink ID="HyperLinkChiTiet" runat="server" 
                                    ImageUrl="~/Hinh/btn_chitiet.jpg" 
                                    NavigateUrl='<%# "../Trang_web/Trang_chi_tiet.aspx?id="+Eval("idSach") %>'>Chi tiết</asp:HyperLink>
                            </td>
                        </tr>
                    </table>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="SoLuongDH" HeaderText="Số lượng">
            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
            </asp:BoundField>
            <asp:BoundField DataField="DonGia" DataFormatString="{0:#,###}" 
                HeaderText="Đơn giá">
            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
            </asp:BoundField>
            <asp:BoundField DataField="ThanhTien" DataFormatString="{0:#,###}" 
                HeaderText="Thành tiền">
            <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
            </asp:BoundField>
        </Columns>
        <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
        <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" />
        <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
        <RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
        <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" />
        <SortedAscendingCellStyle BackColor="#F4F4FD" />
        <SortedAscendingHeaderStyle BackColor="#5A4C9D" />
        <SortedDescendingCellStyle BackColor="#D8D8F0" />
        <SortedDescendingHeaderStyle BackColor="#3E3277" />
    </asp:GridView>
    </div>
    
</asp:Content>

